var member = require('../models/userModel');
var product = require('../models/productModel');
var $ = require('jquery');
var mustache = require('mustache');
var moment = require('moment')();

if (window.console && window.console.log) {
    window.console.log('测试member&product');
    window.console.log(member);
    window.console.log(product);
    window.console.log($);
    window.console.log('end');
    window.console.log(mustache);
    window.console.log(require('moment'))
}
$.cookie('test_time', 'the_value');
setTimeout(function() {
    document.getElementById('root').innerHTML = 'this is a home page.' + 'time:' + moment.format('YYYY-MM-DD HH:mm:ss');
    $(document).pjax('a', '#pjax-container');
}, 3000);


setTimeout(function() {
    var view = {
        title: "2 + 4",
        calc: function() {
            return 2 + 4;
        }
    };
    var output = mustache.render("{{title}} = {{calc}} ", view);
    $("#root").html(output + '&^&' + $.cookie('test_time'));
}, 4500)